'- sdlBrt palette01_converterfromhexcolours.sdlbas > palette01.zxi
dim c[32]

'http://www.colourlovers.com/palette/410644/Intelligence
c[00]=0x303745
c[01]=0x2FD4B0
c[02]=0xD4BE2F
c[03]=0xE9F7CB

'http://www.colourlovers.com/palette/2549771/Arbre_vert
c[04]=0x005E46
c[05]=0x00713D
c[06]=0x89C541
c[07]=0xCEDD2A

'http://www.colourlovers.com/palette/233850/Megalo_no15
c[08]=0xF00000
c[09]=0xF07800
c[10]=0xF0A800
c[11]=0x90C030

'http://www.colourlovers.com/palette/1707607/naya_heather
c[12]=0x5A434D
c[13]=0xFE4F3E
c[14]=0xFBAF26
c[15]=0xFAC14E

'http://www.colourlovers.com/palette/3093604/Chimera_23
c[16]=0xA48946
c[17]=0xE3D5B8
c[18]=0xBC9B94
c[19]=0xE3C48B

'http://www.colourlovers.com/palette/2476286/Subtle_Passion
c[20]=0x69363C
c[21]=0x373738
c[22]=0xD5BF9F
c[23]=0x7C6D61

'http://www.colourlovers.com/palette/1856345/Bird_scout.
c[24]=0x1B0C08
c[25]=0x563C2C
c[26]=0x2F5062
c[27]=0xC9A690

'http://www.colourlovers.com/palette/3014521/herbsspices
c[28]=0xD95A16
c[29]=0xDBB784
c[30]=0x5E5B6C
c[31]=0x5E0505




print"palette01:"
print"'----- bbgggrrr"
print"asm"

for i=0 to 31
  t=c[i]
  b=bitwiseand(t,192)/64:t=int(t/256)
  g=bitwiseand(t,224)/32:t=int(t/256)
  r=bitwiseand(t,224)/32
  f=(b*64)+(g*8)+r
  o$=right$("00000000"+bin$(f),8)
  print "  defb "+o$+"b ;- #"+ucase$(right$("000000"+hex$(c[i]),6))
  next

print"  end asm"



